<template>
  <div class="home">
    <countdown
      v-model="code"
      placeholder="请输入验证码"
      maxlength="6"
      :params="getParams"
      label="短信验证码"
      input-align="right"
    />
    {{ code }}
  </div>
</template>

<script>
// @ is an alias to /src
import countdown from "_c/countdownVerification";
export default {
  name: "HomeIndex",
  data() {
    return {
      code: "",
    };
  },
  components: { countdown },
  methods: {
    getParams() {
      return new Promise((r) => {
        r({
          phone: 18888888888,
        });
      });
    },
  },
};
</script>
